Security News
Introducing the Socket Python SDK
The initial version of the Socket Python SDK is now on PyPI, enabling developers to more easily interact with the Socket REST API in Python projects.
@babel/plugin-transform-unicode-property-regex
Advanced tools
Compile Unicode property escapes in Unicode regular expressions to ES5.
The @babel/plugin-transform-unicode-property-regex package is a plugin for Babel, a JavaScript compiler, that transforms Unicode property escapes in regular expressions into a set of Unicode code points, allowing developers to write more readable and maintainable regular expressions for Unicode characters. This plugin is especially useful when targeting environments that do not support the latest ECMAScript standards.
Transform Unicode Property Escapes
This code sample demonstrates how a Unicode property escape for matching any character in the Greek script is transformed into a regular expression that matches the equivalent set of Unicode code points.
/\p{Script=Greek}/u
The regexpu-core package is a regular expression polyfill that transforms Unicode property escapes and other modern RegExp features to be compatible with older JavaScript environments. It provides similar functionality to @babel/plugin-transform-unicode-property-regex but can be used independently of Babel.
This Babel plugin transforms new RegExp constructors to string literals to ensure compatibility with older environments. While it does not specifically target Unicode property escapes, it addresses the broader issue of RegExp compatibility which is a related concern.
Compile Unicode property escapes in Unicode regular expressions to ES5.
See our website @babel/plugin-transform-unicode-property-regex for more information.
Using npm:
npm install --save-dev @babel/plugin-transform-unicode-property-regex
or using yarn:
yarn add @babel/plugin-transform-unicode-property-regex --dev
v7.24.7 (2024-06-05)
babel-node
babel-traverse
constantViolations
with destructuring (@liuxingbaoyu)babel-helper-transform-fixture-test-runner
, babel-plugin-proposal-explicit-resource-management
using
in switch
correctly (@liuxingbaoyu)babel-helpers
, babel-runtime-corejs2
, babel-runtime-corejs3
, babel-runtime
FAQs
Compile Unicode property escapes in Unicode regular expressions to ES5.
We found that @babel/plugin-transform-unicode-property-regex demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 4 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
The initial version of the Socket Python SDK is now on PyPI, enabling developers to more easily interact with the Socket REST API in Python projects.
Security News
Floating dependency ranges in npm can introduce instability and security risks into your project by allowing unverified or incompatible versions to be installed automatically, leading to unpredictable behavior and potential conflicts.
Security News
A new Rust RFC proposes "Trusted Publishing" for Crates.io, introducing short-lived access tokens via OIDC to improve security and reduce risks associated with long-lived API tokens.